//
//  PlayerManager.h
//  SleepingElf
//
//  Created by karong on 2023/10/17.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

@interface PlayerManager : NSObject
SingletonH

@property (nonatomic, strong) NSArray * musicList;
///播放单个音频
- (void)playWithMusic:(MusicModel *)music;
///同时播放多个音频
- (void)playWithMusics:(NSArray *)musicArray;
///播放歌单中的音频
- (void)playListWithMusic:(MusicModel *)music;

- (BOOL)isPlaying;
- (void)resume;
- (void)pause;
- (BOOL)previous;
- (BOOL)next;


- (BOOL)musicIsPlaying:(MusicModel *)music;
- (MusicModel *)currentPlayingMusic;
- (void)changePlayerVolume:(float)volume music:(MusicModel *)music;
- (CGFloat)playerVolumeWithMusic:(MusicModel *)music;
- (void)defaultMusic:(MusicModel *)music;

- (void)wakeUpWithMusicUrl:(NSString *)musicUrl;
- (void)stopWakeUp;
- (void)keepAlive;
@end

NS_ASSUME_NONNULL_END
